-- GENERATED SPELL FOR [Ahn'kahar Web Winder] --


function spell0_30276(pUnit, Event) --@Tangled Webs,n/a--
pUnit:FullCastSpellOnTarget(56632,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30276', 9500, 1)
end

function spell1_30276(pUnit, Event) --@Web Grab,n/a--
pUnit:FullCastSpellOnTarget(56640,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30276', 0, 1)
end

function spell2_30276(pUnit, Event) --@Web Grab,n/a--
pUnit:FullCastSpellOnTarget(59106,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30276', 0, 1)
end

function Sorts_30276(pUnit, Event)
local choix_sorts_30276 = math.random(0, 2)
if choix_sorts_30276 == 0 then
pUnit:RegisterEvent('spell0_30276', 1, 1)
end
if choix_sorts_30276 == 1 then
pUnit:RegisterEvent('spell1_30276', 1, 1)
end
if choix_sorts_30276 == 2 then
pUnit:RegisterEvent('spell2_30276', 1, 1)
end
end

function mob30276_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_30276', math.random(1500, 3000), 1)
end

function mob30276_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob30276_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob30276_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(30276, 1, 'mob30276_Action')
RegisterUnitEvent(30276, 2, 'mob30276_Leave')
RegisterUnitEvent(30276, 3, 'mob30276_Kill')
RegisterUnitEvent(30276, 4, 'mob30276_Die')
